'use strict';
//controller level
const setting = require('../database/setting');
const examModel = require('../model/Exam');

class Exam {
	examList(callback) {
		setting.MongoClient.connect(setting.URL, (err, db) => {
			examModel.list(db, (result) => {
				callback(result);
			});
		});
	}
}

module.exports = new Exam();